package com.bookstore.entity;

public class OrderItem {
    private Long orderItemId;
    private Long orderId;
    private Long productId;
    //单个商品的购买数量
    private Integer buyNum;

    public OrderItem(Long orderItemId, Long orderId, Long productId, Integer buyNum) {
        this.orderItemId = orderItemId;
        this.orderId = orderId;
        this.productId = productId;
        this.buyNum = buyNum;
    }

    public OrderItem() {
    }

    @Override
    public String toString() {
        return "OrderItem{" +
                "orderItemId=" + orderItemId +
                ", orderId=" + orderId +
                ", productId=" + productId +
                ", buyNum=" + buyNum +
                '}';
    }

    public Long getOrderItemId() {
        return orderItemId;
    }

    public void setOrderItemId(Long orderItemId) {
        this.orderItemId = orderItemId;
    }

    public Long getOrderId() {
        return orderId;
    }

    public void setOrderId(Long orderId) {
        this.orderId = orderId;
    }

    public Long getProductId() {
        return productId;
    }

    public void setProductId(Long productId) {
        this.productId = productId;
    }

    public Integer getBuyNum() {
        return buyNum;
    }

    public void setBuyNum(Integer buyNum) {
        this.buyNum = buyNum;
    }
}
